// import ConfigTxt from "../../config.txt";

// const urlResult = { ConfigTxt };

const path = require("path");

function resolve(dir) {
  return path.join(__dirname, dir);
}

module.exports = {
  lintOnSave: false,
  configureWebpack: {
    resolve: {
      alias: {
        vue$: resolve("node_modules/vue/dist/vue.esm.js")
      }
    }
  },
  devServer: {
    host: "0.0.0.0",
    port: 8081,
    // port: urlResult.ConfigTxt.split(",")[3],
    https: false,
    hotOnly: false,
    proxy: null,
    before: app => {}
  },
  chainWebpack: config => {
    config.module
      .rule("raw")
      .test(/\.txt$/)
      .use("raw-loader")
      .loader("raw-loader")
      .end();
  }
};
